package com.partsoft.loader.context;

public interface ContextServiceAdapter {
	
	void start() throws Exception;
	
	void stop();
	
	public static enum LifeCycleOperation {

		START("启动"),

		STOP("停止");

		private final String title;

		public String getTitle() {
			return title;
		}

		private LifeCycleOperation(String title) {
			this.title = title;
		}

		public static LifeCycleOperation fromName(String value) {
			for (LifeCycleOperation op : LifeCycleOperation.values()) {
				if (op.name().equalsIgnoreCase(value)) {
					return op;
				}
			}
			return null;
		}

	}
	
}
